<?php use_stylesheets_for_form($form) ?>
<?php use_javascripts_for_form($form) ?>

<form action="<?php echo url_for('cliente/'.($form->getObject()->isNew() ? 'create' : 'update').(!$form->getObject()->isNew() ? '?id='.$form->getObject()->getId() : '')) ?>" method="post" <?php $form->isMultipart() and print 'enctype="multipart/form-data" ' ?>>
<?php if (!$form->getObject()->isNew()): ?>
<input type="hidden" name="sf_method" value="put" />
<?php endif; ?>
  <table>
    <tfoot>
      <tr>
        <td colspan="2">
          <?php echo $form->renderHiddenFields(false) ?>
          &nbsp;<?php echo button_to('Volver a la lista', 'cliente/index', array('class'=>'button')); ?>
          <?php if (!$form->getObject()->isNew()): ?>
            &nbsp;<?php echo button_to('Borrar Cliente', 'cliente/delete?id='.$form->getObject()->getId(), array('method' => 'delete', 'confirm' => 'Estas Seguro?')) ?>
          <?php endif; ?>
          <input class="button" type="submit" value="Listo!" />
        </td>
      </tr>
    </tfoot>
    <tbody>
      <?php echo $form->renderGlobalErrors() ?>
      <tr style="border-radius: 5px;">
        <th><?php echo $form['razonSocial']->renderLabel() ?></th>
        <td>
          <?php echo $form['razonSocial']->renderError() ?>
          <?php echo $form['razonSocial'] ?>
        </td>
      </tr>
      <tr style="border-radius: 5px;">
        <th><?php echo $form['cuitCuil']->renderLabel() ?></th>
        <td>
          <?php echo $form['cuitCuil']->renderError() ?>
          <?php echo $form['cuitCuil'] ?>
        </td>
      </tr>
      <tr>
        <th><?php echo $form['tipoIva']->renderLabel() ?></th>
        <td>
          <?php echo $form['tipoIva']->renderError() ?>
          <?php echo $form['tipoIva'] ?>
        </td>
      </tr>
      <tr>
        <th><?php echo $form['direccion']->renderLabel() ?></th>
        <td>
          <?php echo $form['direccion']->renderError() ?>
          <?php echo $form['direccion'] ?>
        </td>
      </tr>
      <tr>
        <th><?php echo $form['ciudad']->renderLabel() ?></th>
        <td>
          <?php echo $form['ciudad']->renderError() ?>
          <?php echo $form['ciudad'] ?>
        </td>
      </tr>
      <tr>
        <th><?php echo $form['codigoPostal']->renderLabel() ?></th>
        <td>
          <?php echo $form['codigoPostal']->renderError() ?>
          <?php echo $form['codigoPostal'] ?>
        </td>
      </tr>
      <tr>
        <th><?php echo $form['pais']->renderLabel() ?></th>
        <td>
          <?php echo $form['pais']->renderError() ?>
          <?php echo $form['pais'] ?>
        </td>
      </tr>
      <tr>
        <th><?php echo $form['telefono']->renderLabel() ?></th>
        <td>
          <?php echo $form['telefono']->renderError() ?>
          <?php echo $form['telefono'] ?>
        </td>
      </tr>
      <tr>
        <th><?php echo $form['celular']->renderLabel() ?></th>
        <td>
          <?php echo $form['celular']->renderError() ?>
          <?php echo $form['celular'] ?>
        </td>
      </tr>
      <tr>
        <th><?php echo $form['email']->renderLabel() ?></th>
        <td>
          <?php echo $form['email']->renderError() ?>
          <?php echo $form['email'] ?>
        </td>
      </tr>
    </tbody>
  </table>
</form>
